export function getChildrenByName(routes,name){
    let result=[]
    for(let i=0;i<routes.length;i++){
        const route=routes[i]
        if(route.name===name){
            result=route.children?route.children.map((a)=>{
                return a.name
            }):[]
            break
        }
        if(route.children){
            result=getChildrenByName(route.children,name)
        }
    }
    return result
}


//判断arr1的所有项是否在arr2中存在
export function isIncludes(arr1,arr2){
    return arr1.every((item)=>{
        return arr2.includes(item)
    })
}